package ynu.czs.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import ynu.czs.entity.User;

@RestController
@RequestMapping("/user")
public class userController {
    @GetMapping("/getUserById/{userId}")
    public User GetUserById(@PathVariable("userId") Integer userId) {
        User user = new User();
        user.setUserId(userId);
        user.setUserName("张三");
        user.setPassword("123456");
        return user;
    }

}
